/*
  Blink
  Turns on an LED on for one second, then off for one second, repeatedly.
 
  This example code is in the public domain.
 */
 
// Pin 13 has an LED connected on most Arduino boards.
// give it a name:
int led_array[4] = {8,9,10};
int switch_array[4] = {1,2,3};
int this = 1;
int that = 2;
// the setup routine runs once when you press reset:
void setup() {                
  // initialize the digital pin as an output.
  Serial.begin(9600);
  for (int i = 0; i < 4; i++)
  {
    Serial.println(led_array[i]);
    Serial.println(switch_array[i]);
    pinMode(led_array[i], OUTPUT);  
    pinMode(switch_array[i], INPUT);  
    digitalWrite(switch_array[i], HIGH);
  }
}

// the loop routine runs over and over again forever:
void loop() {
  
    for (int i = 0; i < 3; i++)
    {
      int val = digitalRead(switch_array[i]);
      if (val == HIGH)
      {
        digitalWrite(led_array[i], LOW);   // turn the LED on (HIGH is the voltage level)
      }
      else
      {
        digitalWrite(led_array[i], HIGH);
      }
    }
  //delay(1000);               // wait for a second
  //digitalWrite(led, LOW);    // turn the LED off by making the voltage LOW
  //delay(1000);               // wait for a second
}
